<?php
use Jialeo\LaravelSchemaExtend\Schema;
//use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateShopOrderEvaluatesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('shop_order_evaluates', function (Blueprint $table) {
            $table->comment = '订单评价表';
            $table->increments('id')->comment('评价ID');
			$table->integer('user_id')->comment('用户id');
			$table->integer('order_id')->comment('订单id');
			$table->integer('product_id')->comment('商品id');
			$table->string('content',100)->nullable()->comment('评价内容');
			$table->string('images',100)->nullable()->comment('图片：多图用|线隔开');
			$table->tinyInteger('level')->comment('星级：1=非常差，2=差，3=一般，4=好，5=非常好');
			$table->tinyInteger('status')->default(1)->comment('是否显示:0=否,1=是');
            $table->timestamp('created_at')->nullable()->comment('创建时间');
			$table->timestamp('updated_at')->nullable()->comment('更新时间');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('shop_order_evaluates');
    }
}
